package ${package}.${moduleName}.model;

import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;
<#list importList as i>
import ${i!};
</#list>
<#if baseClass??>
import ${baseClass.packageName}.${baseClass.name};
</#if>

/**
 * ${tableComment}
 *
 * @author ${author} ${email}
 */
@Data
@AllArgsConstructor
@Builder
@NoArgsConstructor
@ApiModel("${tableComment}")
@Table(name = "${tableName}")
public class ${BeanName}Model<#if baseClass??> extends ${baseClass.name}</#if> {
<#list columnList as column>
  <#if !column.baseAttr>
    <#if column.pkItem>
    @Id
    @GeneratedValue(generator = "JDBC")
    </#if>
    <#if column.attrType == "Date">
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    </#if>
	@ApiModelProperty(name = "${column.attrName}", value = "${column.columnComment}", dataType = "${column.attrType}")
	private ${column.attrType} ${column.attrName};
	
  </#if>
</#list>
}